home *** CD-ROM | disk | FTP | other *** search
- on enterFrame
- global gMovieToPlay, gIndexOfCurrentButton, gMouseDownInButton, gIsMainButton, gIsSmallButton, gChannelForHighLights, gChannelForFreeFlash, gFreeFlashTimerBase, gSmallButtonsOn, gCursorIsHand
- set gCursorIsHand to 0
- set hTemp to the mouseH
- set vTemp to the mouseV
- if gMouseDownInButton then
- if gIsMainButton then
- set iButtonTemp to isPositionWithinMainButton(hTemp, vTemp)
- if iButtonTemp = gIndexOfCurrentButton then
- set the visible of sprite gChannelForHighLights to 1
- updateStage()
- else
- set the visible of sprite gChannelForHighLights to 0
- updateStage()
- end if
- else
- if gSmallButtonsOn then
- set iButtonTemp to isPositionWithinSmallButton(hTemp, vTemp)
- if iButtonTemp = gIndexOfCurrentButton then
- set the visible of sprite gChannelForHighLights to 1
- updateStage()
- else
- set the visible of sprite gChannelForHighLights to 0
- updateStage()
- end if
- end if
- end if
- else
- if (isPositionWithinMainButton(hTemp, vTemp) > 0) or (isPositionWithinSmallButton(hTemp, vTemp) > 0) then
- if not gCursorIsHand then
- cursor([9, 10])
- set gCursorIsHand to 1
- end if
- else
- cursor(-1)
- set gCursorIsHand to 0
- end if
- end if
- if gSmallButtonsOn then
- put "gSmallButtonsOn =", gSmallButtonsOn
- set timeDeltaTemp to the timer - gFreeFlashTimerBase
- if (timeDeltaTemp > 100) and (timeDeltaTemp <= 150) then
- set the visible of sprite gChannelForFreeFlash to 1
- else
- if timeDeltaTemp > 150 then
- set the visible of sprite gChannelForFreeFlash to 0
- set gFreeFlashTimerBase to the timer
- end if
- end if
- end if
- end
-
- on exitFrame
- global gNextLabel, gIsMainButton, gIsSmallButton, gAnisForMainButtons, gIndexOfCurrentButton, gMovieToPlay, gCursorIsHand
- if gMovieToPlay then
- cursor(4)
- set gCursorIsHand to 0
- play movie getAt(gAnisForMainButtons, gIndexOfCurrentButton)
- end if
- go(gNextLabel)
- end
-